package org.demo.patten.template_method;

import java.util.Arrays;
import java.util.List;

/**
 * @author zhuj
 * @date 2025/3/29
 * @apiNote
 */
public class ExcelExporter extends ReportExporter {
    protected List<String> queryData() {
        System.out.println("查询数据库，获取销售数据...");
        return Arrays.asList("订单1", "订单2");
    }
    protected String format(List<String> data) {
        System.out.println("将数据格式化为Excel...");
        return "Excel格式数据";
    }
    protected String writeToFile(String content) {
        System.out.println("写入Excel文件...");
        return "/export/report.xlsx";
    }
}
